package com.hh.bss.auth.controller;

import java.io.IOException;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.servlet.ModelAndView;

import com.hh.bss.base.BaseSpringController;

@Controller
public class mainController extends BaseSpringController {
	
	public String main(HttpServletRequest request, HttpServletResponse response) throws IOException {
		com.hh.bss.auth.client.OnlineManager onlineManager = super.getOnlineManager(request, response);
		request.setAttribute("userId", onlineManager.getOnlineUser().getId());
		return "forward:/main.jsp";
		
		/*
		ModelAndView mv = new ModelAndView();
		mv.setViewName("forward:/main.jsp");		
		
		mv.addObject("userId", onlineManager.getOnlineUser().getId());
		
		response.setCharacterEncoding("UTF-8");
		return mv;
		*/
	}
}
